package org.nstack.header.storage.snapshot;

import org.springframework.http.HttpMethod;
import org.nstack.header.identity.Action;
import org.nstack.header.message.APIDeleteMessage;
import org.nstack.header.message.APIParam;
import org.nstack.header.rest.APINoSee;
import org.nstack.header.rest.RestRequest;


@Action(category = VolumeSnapshotConstant.ACTION_CATEGORY)
@RestRequest(
        path = "/volume-snapshots/{uuid}",
        method = HttpMethod.DELETE,
        responseClass = APIDeleteVolumeSnapshotEvent.class
)
public class APIDeleteVolumeSnapshotMsg extends APIDeleteMessage implements VolumeSnapshotMessage {

    @APIParam(checkAccount = true, operationTarget = true)
    private String uuid;


    @APINoSee
    private String volumeUuid;

    @APINoSee
    private String treeUuid;

    @Override
    public String getTreeUuid() {
        return treeUuid;
    }

    @Override
    public void setTreeUuid(String treeUuid) {
        this.treeUuid = treeUuid;
    }

    public String getUuid() {
        return uuid;
    }

    public void setUuid(String uuid) {
        this.uuid = uuid;
    }

    @Override
    public String getSnapshotUuid() {
        return uuid;
    }

    @Override
    public String getVolumeUuid() {
        return volumeUuid;
    }

    public void setVolumeUuid(String volumeUuid) {
        this.volumeUuid = volumeUuid;
    }
 
    public static APIDeleteVolumeSnapshotMsg __example__() {
        APIDeleteVolumeSnapshotMsg msg = new APIDeleteVolumeSnapshotMsg();

        msg.setUuid(uuid());

        return msg;
    }

}
